import Vue from 'vue'
import Router from 'vue-router'
import routes from './common/router.js'

Vue.use(Router)

let router = new Router({
	mode: 'history',
	routes
})

router.beforeEach((to,from,next)=>{
	// let token = window.sessionStorage.getItem('token')?window.sessionStorage.getItem('token'):''
	
	// if((!token)&&parent.frames.length == 0){
		

	// 	Vue.prototype.$message.error('登录失效，请重新登录')
	// 	location.href = 'http://180.76.96.39:90/?url=' + location.href
		 
	// }
	next() 
})


export default router